<?php
namespace Tbf\Bundle\UpyunBundle\Tests;
use Tbf\Component\FileSystem\FileSystemFunction;
class DownloadTest extends TestCase
{
    protected $kernel;
    public function setUp()
    {
        $this->markTestIncomplete();
        $this->save_path = $this->getParameter('kernel.cache_dir').'/test/upyun_download/';
        FileSystemFunction::delete($this->save_path);
    }
    public function tearDown()
    {
        FileSystemFunction::delete($this->save_path);
    }
    public function testDownloadListFromPhp()
    {
        $this->get('tbf_upyun')->downloadListFromPhp(array(
            '/test/1.txt'
        ),$this->save_path);
        $this->assertEquals('abc',file_get_contents($this->save_path.'/test/1.txt'));
    }
    public function testDownloadList()
    {
        $this->markTestIncomplete();
        $this->get('tbf_upyun')->downloadList(array(
            '/test/1.txt'
        ),$this->save_path);
        $this->assertEquals('abc',file_get_contents($this->save_path.'/test/1.txt'));
    }

}
